Merge alternative readme into main file. Two ways to install phpunit, document them...
authorChad Horohoe <demon@users.mediawiki.org>
Tue, 2 Feb 2010 19:17:14 +0000 (19:17 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Tue, 2 Feb 2010 19:17:14 +0000 (19:17 +0000)
tests/Makefile
tests/README
tests/README.ALTERNATIVE [deleted file]
tests/run-test.php [deleted file]

index 25ccda3..545a8b1 100644 (file)
@@ -1,19 +1,11 @@
 .PHONY: help test
 all test:
-       php run-test.php ArticleTest.php
-       php run-test.php GlobalTest.php
-       php run-test.php DatabaseTest.php
-       php run-test.php ImageFunctionsTest.php
-       php run-test.php SearchMySQL4Test.php
+       phpunit
 install:
-       cvs -z9 -d:pserver:cvsread:@cvs.php.net:/repository/ co -P pear/PHPUnit
-       mv pear/PHPUnit .
-       rm -rf pear
-clean:
-       rm -rf PHPUnit pear
+       pear channel-discover pear.phpunit.de
+       pear install phpunit/PHPUnit
 help:
        # Options:
        #       test (default)          Run the unit tests
-       #       install                 Install PHPUnit from CVS
-       #       clean                   Remove local PHPUnit install
+       #       install                 Install PHPUnit from phpunit.de
        #       help                    You're looking at it!
index 562ee28..b52e790 100644 (file)
@@ -1,5 +1,5 @@
 Some quickie unit tests done with the PHPUnit testing framework. To run the
-test suite, run 'make test' in this dir.
+test suite, run 'make test' in this dir. This directly invokes 'phpunit.'
 
 PHPUnit is no longer maintained by PEAR. To get the current version of
 PHPUnit, first uninstall any old version of PHPUnit or PHPUnit2 from PEAR, 
@@ -7,3 +7,18 @@ then install the current version from phpunit.de like this:
 
 # pear channel-discover pear.phpunit.de
 # pear install phpunit/PHPUnit
+
+You also may wish to install this via your normal package mechanism:
+
+# aptitude install phpunit
+ - or -
+# yum install phpunit
+
+Notes:
+- Label currently broken tests in the group Broken and they will not
+  be run by phpunit.  You can add them to the group by putting the
+  following comment at the top of the file:
+  /**
+   * @group Broken
+   */
+- Need to fix some broken tests
diff --git a/tests/README.ALTERNATIVE b/tests/README.ALTERNATIVE
deleted file mode 100644 (file)
index 4178e09..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-This file describes an alternative way of testing from that in README
-since the README method didn't work for me.
-
- - Put a LocalSettings.php in the parent directory.  If you checked
-   out mediawiki/trunk/phase3 as a directory called mediawiki, then
-   this is where your LocalSettings.php file would go.
- - Install PHPUnit.  I used version 3.3.16 from Ubuntu.
-   ("aptitude install phpunit").
- - Invoke phpunit directly instead of using make.  This uses the
-   phpunit.xml file to run the tests.
- - Fix broken tests.
- - Label currently broken tests in the group Broken and they will not
-   be run by phpunit.  You can add them to the group by putting the
-   following comment at the top of the file:
-
-    /**
-     * @group Broken
-     */
-
-
-
-NOTE: I haven't yet determined why but my PHP installation would
-sometimes segfault while linting the files.  PHPUnit uses "php -l" to
-check file syntax and this is where the segfaults were happening.
diff --git a/tests/run-test.php b/tests/run-test.php
deleted file mode 100644 (file)
index c8d9872..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-<?php
-
-require_once( dirname(__FILE__) . '/../maintenance/commandLine.inc' );
-require( 'PHPUnit/TextUI/Command.php' );